package com.isoft.airportsystem.service.change;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.isoft.airportsystem.common.change.Result;
import com.isoft.airportsystem.entity.change.NotificationRecord;
import com.isoft.airportsystem.entity.change.NotificationSubscription;
import com.isoft.airportsystem.entity.dao.FlightChangeEvent;
import com.isoft.airportsystem.entity.dao.NotificationSubscriptionDTO;
import com.isoft.airportsystem.entity.dao.PageQuery;

// 通知服务
public interface NotificationService {
    // 订阅航班变更
    Result<NotificationSubscription> subscribeFlightChange(NotificationSubscriptionDTO dto);
    // 取消订阅
    Result<Void> unsubscribe(String subscriptionId);
    // 发送变更通知
    void sendChangeNotification(FlightChangeEvent event);
    // 获取通知记录
    Page<NotificationRecord> getNotificationRecords(PageQuery query, String flightId, String status);
}